<template>
	<view class="gjl-components">
		<view class="card-bg">
			<image :src="initConfig.vip_page.vip_card_bg" mode=""></image>
		</view>
		<view class="card-content">
			
			<view class="top">
				<view class="left">
					<view class="card-name">
						<view class="img-box">
							<image src="/static/images/mine/vip.png" mode=""></image>
						</view>
						<view class="name">
							超级会员卡
						</view>
					</view>
					<view class="card-line">
						<image :src="initConfig.vip_page.vip_card_line" mode=""></image>
					</view>
					<view class="card-time">
						有效期：3个月
					</view>
				</view>
				<view class="right">
					<view class="card-price">
						39.90
					</view>
					<view class="card-old-price">
						¥99.00
					</view>
				</view>
			</view>
			<view class="bottom">
				<view class="left">
					赠送3个5元无门槛红包         
				</view>
				<view class="right">
					<view class="btn-bg">
						<image :src="initConfig.vip_page.vip_card_btn" mode=""></image>
					</view>
					<view class="text">
						立即开通
					</view>
				</view>
			</view>
		</view>
	</view>
</template>

<script>
	import {
		mapState
	} from 'vuex';
	export default {
		computed: {
			...mapState({
				initConfig: 'initConfig'
			})
		},
	}
</script>

<style scoped lang="scss">
	.gjl-components{
		position: relative;
		.card-bg{
			position: absolute;
			z-index: 1;
			top: 0;
			left: 0;
			width: 100%;
			height: 100%;
		}
		image{
			height: 100%;
			width: 100%;
		}
		.card-content{
			padding: 40rpx 30rpx 40rpx 40rpx;
			box-sizing: border-box;
			height: 280rpx;
			width: 100%;
			position: relative;
			z-index: 2;
			display: flex;
			flex-direction: column;
			justify-content: space-between;
			.bottom{
				display: flex;
				align-items: flex-end;
				justify-content: space-between;
				.right{
					width: 195rpx;
					height: 64rpx;
					display: flex;
					align-items: center;
					justify-content: center;
					position: relative;
					.btn-bg{
						position: absolute;
						z-index: 1;
						top: 0;
						left: 0;
						width: 100%;
						height: 100%;
						display: flex;
					}
					.text{
						position: relative;
						z-index: 2;
						font-size: 28rpx;
						font-weight: 400;
						color: #000000;
					}
				}
				.left{
					font-size: 24rpx;
					font-weight: 400;
					line-height: 24rpx;
					color: #CBCBCB;
				}
			}
			.top{
				display: flex;
				align-items: flex-start;
				justify-content: space-between;
				.right{
					text-align: right;
					.card-price::before{
						content: '¥';
						font-size: 24rpx;
						font-weight: 400;
						line-height: 24rpx;
						color: #FCE1AC;
					}
					.card-price{
						font-size: 42rpx;
						font-weight: bold;
						line-height: 42rpx;
						color: #FCE1AC;
					}
					.card-old-price{
						margin-top: 20rpx;
						font-size: 24rpx;
						font-weight: 400;
						line-height: 24rpx;
						color: #B1B1B1;
					}
				}
				.left{
					.card-time{
						margin-top: 10rpx;
						font-size: 24rpx;
						font-weight: 400;
						line-height: 24rpx;
						color: #FFEEDC;
					}
					.card-line{
						margin-top: 6rpx;
						height: 5rpx;
						width: 137rpx;
						display: flex;
					}
					.card-name{
						display: flex;
						align-items: center;
						.img-box{
							height: 28rpx;
							width: 33rpx;
							display: flex;
						}
						.name{
							margin-left: 5rpx;
							font-size: 36rpx;
							font-weight: 500;
							line-height: 36rpx;
							color: #FCE1AC;
						}
					}
				}
			}
		}
	}
</style>